home *** CD-ROM | disk | FTP | other *** search
/ Chip: 2001 Haziran / CHIP Haziran2001.iso / prog / haziran / 20 / setup.exe / {app} / plugins / XQ Windows Update 1.xpl < prev    next >
Encoding:
XSetup plugin  |  2001-03-28  |  2.2 KB  |  81 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="5"
  3. "COUNT"="2"
  4. "UIPATH"="System\User Data"
  5. "NAME"="Windows Update Registration"
  6. "VERSION"="1.36"
  7. "OSVERSION"="00111"
  8. "LANGUAGE"="VBScript"
  9. "TEXT 1"="Set Registration Done"
  10. "TEXT 2"="Undo "Registration Done""
  11. "DESCRIPTION 1"="Before you can use the Windows Update features, you normally have to register in order to use this service."
  12. "DESCRIPTION 2"="By clicking on the "Set Registration Done" button, you can use this service WITHOUT registration, so no data from your computer is sent to microsoft.com."
  13. "DESCRIPTION 3"="NOTE: "Windows Update" is not available for Windows 95 or NT."
  14. "AUTHOR"="Xteq Systems"
  15. "CONTACTURL"="http://www.xteq.com"
  16. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  17. "COMMENT 1"=" "
  18. "COMMENT 2"="Thanks to Steve Mears [mearss@cybernet1.com] for the UNDO idea!"
  19. "COMMENT 3"="Thanks to Anonymous [anonymous@anonymizer.com] for the bug fix of the UNDO patch!"
  20.  
  21.  
  22. sP1=""
  23. sP2=""
  24.  
  25. sP1_98="HKLM\Software\Microsoft\Windows\CurrentVersion\RegDone"
  26. sP2_98="HKLM\Software\Microsoft\Windows\CurrentVersion\Welcome\RegWiz\@"
  27.  
  28. sP1_2K="HKLM\Software\Microsoft\Windows NT\CurrentVersion\RegDone"
  29. sP2_2K="HKLM\Software\Microsoft\Windows NT\CurrentVersion\Welcome\RegWiz\@"
  30.  
  31. Sub Plugin_Initialize 
  32.     if GetWinVer=3 or GetWinVer=5 then
  33.        sP1=sP1_98
  34.        sP2=sP2_98 
  35.     end if
  36.  
  37.     if GetWinVer=4 then
  38.        sP1=sP1_2K
  39.        sP2=sP2_2K 
  40.     end if   
  41. End Sub
  42.  
  43. Sub Plugin_CheckData(ElementIndex)
  44. End Sub
  45.  
  46. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  47.  i=ElementIndex
  48.  Select Case i
  49.  
  50.   Case 1
  51.    Call RegWriteValue(sP1,"1",1)
  52.    
  53.    Call RegWriteValue(sP2,"1",1)
  54.  
  55.    Call MsgInformation("Information updated. You can now access Windows Update without registering.")
  56.  
  57.  
  58.   Case 2
  59.    s=sP1
  60.    v=RegReadValue(s)
  61.    if IsEmpty(v)=false then
  62.       Call RegDeleteValue(s)
  63.    end if
  64.   
  65.    s=sP2
  66.    v=RegReadValue(s)
  67.    if IsEmpty(v)=false then
  68.       'Call RegDeleteValue(s) 'can't be deleted as it's the default value! 
  69.       Call RegWriteValue(s,"",1)
  70.    end if
  71.  
  72.  
  73.    Call MsgInformation("Registration done information deleted. You can now use Windows Update again.")
  74.  
  75.  
  76.  end select
  77. End Sub
  78.  
  79. Sub Plugin_Terminate 
  80. End Sub
  81.